#include <stdio.h>

int main()
{
    double x;
    int y;
    printf("Input x\n");
    scanf("%lf", &x);
    if( x != 0.0 )
    {
        if( x > 0.0 )
            y = 1;
        if( x < 0.0 )
            y = -1;
    }
    else
    {
        y = 0;
    }
    printf("y = %d\n", y);
    return 0;
}